<extend name="Layout/page_detail" />
<block name="content">
{:W('PageHeader/simple',array('name'=>'用户设置','search'=>'N'))}

<div class="operate panel panel-default">
	<div class="panel-body">
		<div class="pull-right">
			<a onclick="save()"  class="btn btn-sm btn-primary">保存</a>
		</div>
	</div>
</div>
<form method='post' id="form_data" class="well form-horizontal">	
	<input type="hidden" name="ajax" id="ajax" value="0">
	<div class="form-group">
		<label class="col-sm-2 control-label" for="list_rows">列表数量：</label>
		<div class="col-sm-10">
			<input class="form-control col-20" type="text" id="list_rows" name="list_rows" value="{$config.list_rows}" check="number" msg="必须是数字">
		</div>
	</div>
	<div class="form-group">
		<label class="col-sm-2 control-label" for="list_rows">网页推送：</label>
		<div class="col-sm-10">
			<label class="col-6">
					<input name="push_web[]" class="ace push_web" type="checkbox" value="mail">
					<span class="lbl">邮件</span>
			</label>
			<label class="col-6">
					<input name="push_web[]" class="ace push_web" type="checkbox" value="flow">
					<span class="lbl">流程</span>
			</label>
			<label class="col-6">
					<input name="push_web[]" class="ace push_web" type="checkbox" value="info">
					<span class="lbl">信息</span>
			</label>
			<label class="col-6">
					<input name="push_web[]" class="ace push_web" type="checkbox" value="message">
					<span class="lbl">消息</span>
			</label>
		</div>
	</div>
	<div class="form-group">
		<label class="col-sm-2 control-label" for="list_rows">微信推送：</label>
		<div class="col-sm-10">
			<label class="col-6">
					<input name="push_wechat[]" class="ace push_wechat" type="checkbox" value="mail">
					<span class="lbl">邮件</span>
			</label>
			<label class="col-6">
					<input name="push_wechat[]" class="ace push_wechat" type="checkbox" value="flow">
					<span class="lbl">流程</span>
			</label>
			<label class="col-6">
					<input name="push_wechat[]" class="ace push_wechat" type="checkbox" value="info">
					<span class="lbl">信息</span>
			</label>
			<label class="col-6">
					<input name="push_wechat[]" class="ace push_wechat" type="checkbox" value="message">
					<span class="lbl">消息</span>
			</label>
		</div>
	</div>
</form></block>
<block name="js">
<script type="text/javascript">
	function save() {
		if (check_form("form_data")) {
			sendForm("form_data", "{:U('save')}");
		}
	};

	$(document).ready(function() {
		set_return_url();
		set_val('push_web',"{$config.push_web}");
		set_val('push_wechat',"{$config.push_wechat}");
	});
</script>
</block>